class ServicesController < ApplicationController
	before_filter :find_structure 
	
	def index
		options = {:page=>params[:page], :per_page=>10}
		@services = @structure.posts.paginate(:all, options)
	end	
	
	def show
		@service = Post.find(params[:id])
	end
	
	private
	
	def find_structure
		@structure = Structure.by_kind(:services).find(:first)
	end
end
